<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <link rel="stylesheet" href="/css/list.css">
    <title>账单</title>
</head>
<body>
    <div class="list">
        <h1>账单列表</h1>
        <hr />
        <ul>
            <% accounts.forEach(item => { %>
                <li>
                    <div class="time <%= item.type == '-1'? 'time-out':'time-in' %>">
                        <%= item.time %>
                    </div>
                    <div class="content">
                        <p class="title"><%= item.title %></p>
                        <div class="type <%= item.type == '-1'? 'type-out':'type-in' %>"><%= item.type == '1'? '支出':'收入' %></div>
                        <p class="money"><%= item.money %>元</p>
                        <div class="close"><a href="/account <%= item._id %>">x</a></div>
                    </div>

                </li>
            <% }) %>
        </ul>
    </div>
</body>
</html>